<extend name="Layout:layout_list" />
<block name="body_content_block">
    <table id="main_grid" class="easyui-datagrid" data-url="{:AddonU('XTool/get_databackup_list_json')}"></table>
    <div id="tb" style="padding:2px 5px;">
        <div style="margin-bottom: 5px; border-bottom:solid 1px #dddddd;">
            <a href="{:AddonU('XTool/data_backup_save','type=schema')}" class="easyui-linkbutton lnk_grid_process">备份结构</a>
            <a href="{:AddonU('XTool/data_backup_save','type=data')}" class="easyui-linkbutton lnk_grid_process">备份数据</a>
            <a href="{:AddonU('XTool/data_delete_save','id=varid')}" class="easyui-linkbutton lnk_grid_remove" iconCls="icon-remove" plain="true">删除</a>
        </div>
    </div>
</block>
<block name="body_after_block">
    <script type="text/javascript">
        // 页面初始化
        curd_grid.config({
            title: '数据备份管理',
            toolbar: '#tb',
            columns: [[
                    {field: 'ck', checkbox: true},
                    {title: "日期", field: "createdTime", sortable: true},
                    {title: "文件名称", field: "fileName", sortable: true},
                    {title: "大小", field: "fileSizeText", sortable: true},
                    {title:"下载",field:"filePath",formatter:function(value,row){
                       return '<a href="'+value+'" target="_blank">下载</a>';
                    }},
                ]],
        });
        curd_grid.init();
    </script>
</block>